<?php
class Group extends AppModel {
    var $name = 'Group';
    var $primaryKey = 'id';
    var $displayField = 'group_name';
    var $actsAs = array('Acl' => array('requester'));


	 function parentNode(){
                if (!$this->id) {
                return null;
                }
                $data = $this->read();

                if (!$data['Group']['parent_id']){
                        return null;
                } else {
                        return $data['Group']['parent_id'];
                }
        }

    var $hasMany = array(
        'User'
    );
}
?>
